//
// Created by wze-zero on 2024/7/9 009.
//
#include <iostream>
#include <iomanip>

using namespace std;

int main() {
    double h, sum = 0, num;
    int n;
    cin >> h;
    cin >> n;
    num = h;
    for (int i = 0; i < n; ++i) {
        sum += num;
        if (h > 0) {
            h = h / 2;
            num = h * 2;
        } else {
            h = 0;
        }
    }
    cout << setiosflags(ios::fixed) << setprecision(1) << sum << " " << h << endl;
    return 0;
}
